<template>
	<view>
		<navbar :config="config" backColor="#000"></navbar>
		<view class="regional-agency">
			<view class="ql-editor-box" v-html="content"></view>
			<view class="regional-agency-btn" @click.stop="reserveBtn()">
				<view class="reserve-btn">立即预定</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				content: '',
				config: {
					back: true, //false是tolbar页面 是则不写
					title: '区域代理',
					color: '#000',
					//背景颜色;参数一：透明度（0-1）;参数二：背景颜色（array则为线性渐变，string为单色背景）
					backgroundColor: [1, "#fff"],
					statusBarFontColor: '#1A1A1A',
					backIconColor: "#000"
				}
			}
		},
		created() {
			// this.getCode()
		},
		onShow() {
			this.getProtocol()
		},
		methods: {

			getProtocol() {
				this.$http.get(`/protocolConfig/info/area-agent`)
					.then(res => {
						if (res.code == 200) {
							this.content = res.data.content
						}
					})
			},
			// 区域代理
			reserveBtn() {
				uni.navigateTo({
					url: '/pages/user/regional-agency/reserve'
				})
			},
		}
	}
</script>

<style lang="scss" scoped>
	.regional-agency {
		width: 100%;
		padding: 48rpx 39rpx 160rpx;

		.regional-agency-btn {
			position: fixed;
			bottom: 0;
			left: 0;
			width: 100%;
			padding: 40rpx;
			// background-color: #fff;
			font-size: 32rpx;
			font-family: PingFang SC, PingFang SC-Regular;
			font-weight: 400;
			color: #ffffff;

			.reserve-btn {
				
				text-align: center;
				line-height: 96rpx;
				
				width: 673rpx;
				height: 96rpx;
				background: #FF211F;
				border-radius: 19rpx 19rpx 19rpx 19rpx;
			}
		}
	}
</style>